
#include "fx2.h"
#include "fx2regs.h"

//----------- I2C - DAC5571 --------------------------//
#define DAC5571_ADDRESS	0x98
	 
//----------- I2C - DAC5571 --------------------------//

//bit I2CRead(BYTE addr, BYTE length, BYTE xdata *buf);
bit I2CWrite(BYTE addr, BYTE length, BYTE xdata *buf);	 //registro, cant de bytes, dato
void I2CWaitForStop();
//void WaitForI2CWrite();
//bit I2CWaitForDone();
bit I2CWaitForAck();
void I2CStartAndAddrW();
//void I2CStartAndAddrR();

extern bit SetDAC5571(BYTE valor, BYTE modo);
